HTMLify
contact us.html
Views: 698 | Author: sachinthakur
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 | <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Contact Us - I-tech computer education centre</title> </head> <body> <header> <h1>Contact Us<br> I-TECH COMPUTER EDUCATION CENTRE</h1> <p>Bamrauli Katara Agra </p> </header> <section> <form id="contactForm"> <label for="name">Name:</label> <input type="text" id="name" name="name" required> <label for="email">Email:</label> <input type="email" id="email" name="email" required> <label for="mobile">mobile </label> <input type="mobile" id="mobile" name="mobile" required> <label for="message">Message:</label> <textarea id="message" name="message" rows="4" required></textarea> <button type="button" onclick="submitForm()">Submit</button> </form> </section> <style> body { font-family: Arial, sans-serif; margin: 0; padding: 0; background-image: url("https://images.unsplash.com/photo-1571857089849-f6390447191a?w=500&auto=format&fit=crop&q=60&ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxzZWFyY2h8MTF8fGNvbXB1dGVyJTIwY2xhc3N8ZW58MHx8MHx8fDA%3D") } header { background-color: #536298; color: #fff; text-align: center; padding: 1em 0; } section { max-width: 600px; margin: 20px auto; padding: 20px; background-color: #04ff6c; box-shadow: 0 0 10px rgba(0, 0, 0, 0.1); } form { display: grid; gap: 15px; } label { font-weight: bold; } input, textarea { width: 100%; padding: 10px; box-sizing: border-box; } button { background-color: #1e879c; color: #fff; border: none; padding: 10px 20px; cursor: pointer; } button:hover { background-color: #ef0c0c; } </style> <script> function submitForm() { var name = document.getElementById("name").value; var email = document.getElementById("email").value; var message = document.getElementById("message").value; if (name === "" || email === "" || message === "") { alert("Please fill in all fields."); } else { alert("Form submitted!\n\nName: " + name + "\nEmail: " + email + "\nMessage: " + message); document.getElementById("contactForm").reset(); } } </script> </body> </html> |